package com.welsy.usermgt.business
{
	import mx.rpc.IResponder;
	import com.adobe.cairngorm.business.ServiceLocator;
	import mx.rpc.AbstractOperation;
	import mx.rpc.AsyncToken;
	import com.welsy.usermgt.model.UserMgtModelLocator;
	import mx.rpc.soap.mxml.WebService;
	import flash.profiler.showRedrawRegions;
	import mx.controls.Alert;
	
	
	public class GetSrcCriteriaDelegate
	{
			public var responder : IResponder;
			public var service : Object;
						
			public function GetSrcCriteriaDelegate(responder : IResponder) {
				this.responder = responder;
				this.service = ServiceLocator.getInstance().getWebService("UserMgtService") as WebService;
			}
			
			public function getSrcCriteria() : void {
				var op : AbstractOperation = service.getOperation("GetSearchCriteria");
				op.arguments.GetSearchCriteriaRequest.SubSystemId = UserMgtModelLocator.getInstance().srcCriteriaSSID;
				
				var token : AsyncToken = service.GetSearchCriteria();
				token.addResponder(responder);
			}
	}
}